package cn.com.nes.site.service.crm.customer;

import cn.com.nes.mybatis.agent.crm.entity.CustomerStaff;
import cn.com.nes.site.service.crm.customer.bo.CustomerStaffBO;
import cn.com.nes.site.service.crm.customer.dto.CustomerStaffDTO;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;

public interface CustomerStaffService extends IService<CustomerStaff> {

    /**
     * 获取客户联系人
     */
    List<CustomerStaffDTO> getCustomerStaffList(CustomerStaffBO customerStaffBo);

    //获取主联系人
    CustomerStaffDTO getMainCustomerStaff(String customerUUid);
    /**
     * 获取客户联系人分页
     * @param customerStaffBO
     * @return
     */
    Page<CustomerStaffDTO> getCustomerStaffPage(CustomerStaffBO customerStaffBO) throws Exception;


    /**
     * 保存客户联系人
     * @param customerStaffBO
     * @return
     * @throws Exception
     */
    CustomerStaff saveCustomerStaff(CustomerStaffBO customerStaffBO) throws Exception;

    /**
     * 判断是否为户主
     * @param CustomerUuid
     * @return
     * @throws Exception
     */
    public CustomerStaffDTO getHouseholdCustomerStaff(String CustomerUuid);

    /**
     * 删除客户联系人，可批量
     * @param customerStaffBO
     * @throws Exception
     */
    void deleteCustomerStaff(CustomerStaffBO customerStaffBO) throws Exception;


    /**
     * Retrieves a list of customer staff members based on provided parameters.
     *
     * @param concat   A string to concatenate with other search parameters, enhancing the query's specificity.
     * @param phone    The contact phone number of the customer staff member.
     * @param customerUuid The unique identifier of the customer associated with the staff members.
     * @return CustomerStaff A representation of the customer staff list that matches the given criteria.
     * @throws Exception If an error occurs during the retrieval process.
     */
    CustomerStaff getCustomerStaffList(String concat, String phone, String customerUuid) throws Exception;

}




